<!DOCTYPE html>
<html style="font-size:62.5%">

	<head>
		<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
		<title>欢瑞世纪影视传媒</title>
		<meta name='viewport' content='width=device-width, initial-scale=1.0, maximum-scale=1.0' />
		<link rel="stylesheet" href="css/reset.css">
		<link rel="stylesheet" href="css/font-awesome.min.css">
		<link rel="stylesheet" href="css/swiper.min.css">
		<link rel="stylesheet" type="text/css" href="css/main.css" />
		<script src="js/jquery.min.js"></script>
		<script src="js/swiper.min.js"></script>
		<script src="js/public.js"></script>
	</head>

	<body>
		<div class="personlist">
			<div class="bgtop"></div>
			<div class="persondata">
				<div class="data-con">
					<a href="#" class="tx"><img src="images/lyf.jpg" /></a>
					<div class="personname">
						<h1>李易峰<i class="fa fa-man"></i></h1>
						<span>粉丝<em>3.6万</em></span>
					</div>
					<a href="#" class="concern">关注</a>
					<div class="clear"></div>
				</div>
				<p class="introduce">个人简介：<em>1987年5月4日出生于四川成都，中国内地男演员、流行歌手、影视制片人。</em></p>
				<a href="#" class="detail-data"><i class="fa fa-angle-double-down"></i>详细资料</a>
			</div>
			<div class="swiper-container" id="header">
				<div class="swiper-wrapper">
					<div class="swiper-slide"><a href="#" class="current">作品</a></div>
					<div class="swiper-slide"><a href="#">视频</a></div>
					<div class="swiper-slide"><a href="#">直播</a></div>
					<div class="swiper-slide"><a href="#">新闻</a></div>
					<div class="swiper-slide"><a href="#">周边</a></div>
					<div class="swiper-slide"><a href="#">视频</a></div>
					<div class="swiper-slide"><a href="#">相册</a></div>
					<div class="swiper-slide"><a href="#">直播</a></div>
					<div class="swiper-slide"><a href="#">新闻</a></div>
					<div class="swiper-slide"><a href="#">周边</a></div>
				</div>
			</div>
			<div class="workslist">
				<div class="works">
					<p><i class="fa fa-movie"></i>电影作品</p>
					<div class="swiper-container slide" id="list-o">
						<div class="swiper-wrapper">
							<div class="swiper-slide">
								<a href="detail.html"><img src="images/lyf.jpg"/></a>
								<p>老炮儿</p>
								<p>饰<em>张晓波</em></p>
							</div>
							<div class="swiper-slide">
								<a href="#"><img src="images/lyf02.jpg"/></a>
								<p>怦然心动</p>
								<p>饰<em>苏星宇</em></p>
							</div>
							<div class="swiper-slide">
								<a href="#"><img src="images/lyf03.jpg"/></a>
								<p>老炮儿</p>
								<p>饰<em>张晓波</em></p>
							</div>
							<div class="swiper-slide">
								<a href="#"><img src="images/lyf04.jpg"/></a>
								<p>心动</p>
								<p>饰<em>苏星宇</em></p>
							</div>
							<div class="swiper-slide">
								<a href="#"><img src="images/lyf.jpg"/></a>
								<p>老炮儿</p>
								<p>饰<em>张晓波</em></p>
							</div>
							<div class="swiper-slide">
								<a href="#"><img src="images/lyf02.jpg"/></a>
								<p>怦然心动</p>
								<p>饰<em>苏星宇</em></p>
							</div>
						</div>
					</div>
				</div>
				<div class="works">
					<p><i class="fa fa-tvname"></i>电视作品</p>
					<div class="swiper-container slide" >
						<div class="swiper-wrapper">
							<div class="swiper-slide">
								<a href="#"><img src="images/lyf02.jpg"/></a>
								<p>老炮儿</p>
								<p>饰<em>张晓波</em></p>
							</div>
							<div class="swiper-slide">
								<a href="#"><img src="images/lyf.jpg"/></a>
								<p>怦然心动</p>
								<p>饰<em>苏星宇</em></p>
							</div>
							<div class="swiper-slide">
								<a href="#"><img src="images/lyf03.jpg"/></a>
								<p>老炮儿</p>
								<p>饰<em>张晓波</em></p>
							</div>
							<div class="swiper-slide">
								<a href="#"><img src="images/lyf04.jpg"/></a>
								<p>心动</p>
								<p>饰<em>苏星宇</em></p>
							</div>
							<div class="swiper-slide">
								<a href="#"><img src="images/lyf02.jpg"/></a>
								<p>老炮儿</p>
								<p>饰<em>张晓波</em></p>
							</div>
							<div class="swiper-slide">
								<a href="#"><img src="images/lyf.jpg"/></a>
								<p>怦然心动</p>
								<p>饰<em>苏星宇</em></p>
							</div>
						</div>
					</div>
				</div>
				<a href="#" class="open">打开娱丸app查看更多内容</a>
			</div>
		</div>
		<div class="download">
			<a href="#"><img src=""/></a>
			<a href="#" class="reload">前往下载</a>
		</div>
		<script type="text/javascript">
			window.onload = function() {
			  var mySwiper = new Swiper('#header',{
				  freeMode : true,
				  slidesPerView : 'auto',
				  freeModeSticky : true ,
			  });
			  var mySwiper1 = new Swiper('.slide',{
				  freeMode : true,
				  slidesPerView : 'auto',
				  spaceBetween : 10,
				  freeModeSticky : true ,
			  });
			}
			$('#header .swiper-slide a').click(function(){
				$('#header .swiper-slide a').removeClass('current');
				$(this).addClass('current');
			});
				/*数据请求*/
			$(document).ready(function(){
				function GetQueryString(name) {
					var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
					var r = window.location.search.substr(1).match(reg); //获取url中"?"符后的字符串并正则匹配
					var context = "";
					if (r != null)
						context = r[2];
					reg = null;
					r = null;
					return context == null || context == "" || context == "undefined" ? "" : context;
				}
				var starId = GetQueryString('starId');
				$.ajax({
					url:'http://api.yuwantop.com/star/star?starId='+starId,
					type:'get',
					dataTypt:'json',
					timeout:'1000',
					cache:'false',
					error: erryFunction,
					success: succFunction
				});
				function erryFunction() {

				}
				function succFunction(tt) {
					console.log(tt.data)
					/*for(var i = _index; i <= 18 ; i++){
						var newdate = new Date(tt.data[i].star.birthDate);
						var str="";
						str+=newdate.getYear()+"/";
						str+=(newdate.getMonth()+1)+"/";
						str+=newdate.getDate();
						var html = ' <div class="swiper-slide swiper-slide-p">' +
							'<a href="person_list.html#'+tt.data[i].star.id+'">'+
							'<div class="p-item-box">'+
							'<div class="p-img-box"><img src="'+tt.data[i].star.avatar+'" alt=""></div>'+
							'<div class="p-txt-box">'+
							'<p class="t"><em>'+tt.data[i].star.name +'</em></p>'+
							'<p class="p-detail">生日：<em>'+str+'</em></p>'+
							'<p class="p-detail">代表作：<em>'+ tt.data[i].star.birthDateStr+'</em></p>'+
							'<p class="p-detail">主要成就： <em>'+ tt.data[i].star.reward+'</em></p></div></div></a> </div>'
						$('.p-box').append(html);

						var bg_img = '<div class="swiper-slide bg-img-box"><div class="bg-img"> <img src="'+tt.data[i].star.avatar+'" alt=""> </div> </div>';
						$('.bg-img-list').append(bg_img);
						_index=i;
					}*/
				}
				$.ajax({
					url:'http://api.yuwantop.com/content/contents?type=TV',
					type:'get',
					dataTypt:'json',
					timeout:'1000',
					cache:'false',
					error: erryFunction,
					success: succFunction2
				});
				function erryFunction() {

				}
				function succFunction2(tt) {
					console.log(tt.data)
					/*for(var i = _index; i <= 18 ; i++){
						var newdate = new Date(tt.data[i].star.birthDate);
						var str="";
						str+=newdate.getYear()+"/";
						str+=(newdate.getMonth()+1)+"/";
						str+=newdate.getDate();
						var html = ' <div class="swiper-slide swiper-slide-p">' +
							'<a href="person_list.html#'+tt.data[i].star.id+'">'+
							'<div class="p-item-box">'+
							'<div class="p-img-box"><img src="'+tt.data[i].star.avatar+'" alt=""></div>'+
							'<div class="p-txt-box">'+
							'<p class="t"><em>'+tt.data[i].star.name +'</em></p>'+
							'<p class="p-detail">生日：<em>'+str+'</em></p>'+
							'<p class="p-detail">代表作：<em>'+ tt.data[i].star.birthDateStr+'</em></p>'+
							'<p class="p-detail">主要成就： <em>'+ tt.data[i].star.reward+'</em></p></div></div></a> </div>'
						$('.p-box').append(html);

						var bg_img = '<div class="swiper-slide bg-img-box"><div class="bg-img"> <img src="'+tt.data[i].star.avatar+'" alt=""> </div> </div>';
						$('.bg-img-list').append(bg_img);
						_index=i;
					}*/
				}
			})
		</script>
	</body>

</html>